home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 February
/
EnigmA AMIGA RUN 04 (1996)(G.R. Edizioni)(IT)[!][issue 1996-02][Skylink CD III].iso
/
earcd
/
util1
/
shell-10.lha
/
shell-1.0
/
test_unix_if
< prev
Wrap
Text File
|
1995-12-07
|
696b
|
49 lines
set file test_if3
if [ -L $file ]
then
echo $file is a link
elif [ -S $file ]
then
echo $file is a socket
elif [ -b $file ]
then
echo $file is a block special
elif [ -c $file ]
then
echo $file is a character special
elif [ -d $file ]
then
echo $file is a directory
elif [ -f $file ]
then
echo $file is a regular file
fi
if [ -e $file ]
then
echo $file exists
fi
if [ -r $file ]
then
echo $file is readable
fi
if [ -w $file ]
then
echo $file is writable
fi
if [ -r $file ]
then
echo $file is executable
fi
set file2 test_if
list ($file|$file2)
if [ $file -nt $file2 ]
then
echo $file is newer than $file2
else
echo $file is older than $file2
fi